class GameOfLife{
    private String[] m;
    public GameOfLife(int n){
        m = new String[n];
    }
    void initialize(){
    	String x;
    	for (int i = 0; i < m.l; i++){
    		for (int j = 0; i < m.l; j++){
    			if ((j+i)%2 == 0){
    				x = ".";
    				else {
    					x = "*";
    				}
    			}
    		m[i]= m[i].concat(x);
    		}
    	}
    }
    void print(){
        for(int i = 0; i < m.length; i++){
            System.out.println(m[i]);
        }
    }
    int countNeighbors(int i, int j){
    }
    void iterate(){
        for(int i = 0; i < m.length; i++){
            String line = "";
            for(int j = 0; j < m[i].length(); j++){
                if(countNeighbors(i,j) < 2)
                    line += '.';
                else if(m[i].charAt(j) == '*' && countNeighbors(i,j) > 3){
                    line += '.';
                }
                else if(countNeighbors(i,j) > 3){
                    line += '*';
                }
            }
            m[i] = line;
        }
    }
    void simulateLife(int count){
        for(int i = 0; i < count; i++){
            print();
            iterate();
        }
    }

}
